// 企业端门户
import Layout from "@/layout/company/index"

let baseURL = '/api-user'  // axios 代理baseUrl

/*
*  navAactive 用于顶部菜单显示位置
* */
const companyRouter = [
  {
    path: "/home",
    component: Layout,
    redirect: "/home/index",
    name: "",
    meta: {
      title: "控制台",
      icon: "",
      baseURL, // 用于本地代理连接
      appealWebType: "console" // 用于切换顶部导航，对应左侧栏模块展示，只需要放在父级，子级不需要
    },
    children: [
      {
        path: "index",
        name: "index",
        component: () => import(/* webpackChunkName: "home" */ "@/views/company/home"),
        meta: { title: "首页", icon: "" , navAactive : 'index'}
      },
      {
        path: "message",
        name: "message",
        component: () => import(/* webpackChunkName: "home" */ "@/views/company/message"),
        meta: { title: "消息中心", icon: "" , navAactive : 'index'}
      },
      {
        path: "policy",
        name: "policy",
        component: () => import(/* webpackChunkName: "policy" */ "@/views/company/policy"),
        meta: { title: "政策法规", icon: "",  navAactive : 'policy'}
      },
      {
        path: "policy-details",
        name: "policy-details",
        component: () => import(/* webpackChunkName: "news" */ "@/views/company/news-details"),
        meta: { title: "政策法规——文章详情", icon: "" , navAactive : 'policy'}
      },
      {
        path: "news",
        name: "news",
        component: () => import(/* webpackChunkName: "news" */ "@/views/company/news"),
        meta: { title: "新闻动态", icon: "",  navAactive : 'news'}
      },

      {
        path: "news-details",
        name: "news-details",
        component: () => import(/* webpackChunkName: "news" */ "@/views/company/news-details"),
        meta: { title: "新闻动态——文章详情", icon: "" , navAactive : 'news'}
      },

      {
        path: "shop",
        name: "shop",
        component: () => import(/* webpackChunkName: "shop" */ "@/views/company/shop"),
        meta: { title: "大数据商城", navAactive : 'shop'}
      },
      {
        path: "shop-details",
        name: "shop-details",
        component: () => import(/* webpackChunkName: "shop" */ "@/views/company/shop-details"),
        meta: { title: "大数据商城", navAactive : 'shop'}
      },
    ]
  },
]

export default companyRouter
